package jsyf.oa.entity.tmpEvent;

import com.alibaba.fastjson.JSONObject;

import java.util.Date;

import javax.persistence.Entity;
import javax.persistence.Table;

import jsyf.oa.ientity.BaseEntity;

@Entity
@Table(name = "T_TMP_EVENT_AUDIT", schema = "oa", catalog = "")
public class EventAuditEntity extends BaseEntity {

    private String fkEventId;
    private String auditorId;
    private String auditorName;
    /**
     * 同主表EventMain
     */
    private String auditFlag;
    private Integer auditSort;
    private Date auditTime;
    private String auditAdvise;

    public String getFkEventId() {
        return fkEventId;
    }

    public void setFkEventId(String fkEventId) {
        this.fkEventId = fkEventId;
    }

    public String getAuditorId() {
        return auditorId;
    }

    public void setAuditorId(String auditorId) {
        this.auditorId = auditorId;
    }

    public String getAuditorName() {
        return auditorName;
    }

    public void setAuditorName(String auditorName) {
        this.auditorName = auditorName;
    }

    public String getAuditFlag() {
        return auditFlag;
    }

    public void setAuditFlag(String auditFlag) {
        this.auditFlag = auditFlag;
    }

    public Integer getAuditSort() {
        return auditSort;
    }

    public void setAuditSort(Integer auditSort) {
        this.auditSort = auditSort;
    }

    public Date getAuditTime() {
        return auditTime;
    }

    public void setAuditTime(Date auditTime) {
        this.auditTime = auditTime;
    }

    public String getAuditAdvise() {
        return auditAdvise;
    }

    public void setAuditAdvise(String auditAdvise) {
        this.auditAdvise = auditAdvise;
    }

    @Override
    public JSONObject getJSONObject() {
        JSONObject obj = new JSONObject();
        obj.put("ID", id);
        obj.put("FK_EVENT_ID", fkEventId);
        obj.put("AUDITOR_ID", auditorId);
        obj.put("AUDITOR_NAME", auditorName);
        obj.put("AUDIT_FLAG", auditFlag);
        obj.put("AUDIT_SORT", auditSort);
        obj.put("AUDIT_TIME", auditTime);
        obj.put("AUDIT_ADVISE", auditAdvise);
        return obj;
    }

    @Override
    public String getTableName() {
        return "T_TMP_EVENT_AUDIT";
    }

    @Override
    public JSONObject getJSONColumns() {
        JSONObject obj = new JSONObject();
        obj.put("ID", "id");
        obj.put("FK_EVENT_ID", "fkEventId");
        obj.put("AUDITOR_ID", "auditorId");
        obj.put("AUDITOR_NAME", "auditorName");
        obj.put("AUDIT_FLAG", "auditFlag");
        obj.put("AUDIT_SORT", "auditSort");
        obj.put("AUDIT_TIME", "auditTime");
        obj.put("AUDIT_ADVISE", "auditAdvise");
        return obj;
    }

}
